package com.ibeifeng.thread;

public class TestThread02 {
	public static void main(String[] args) {
		new TestThread02().begin();
		for(int i=0;i<10;i++){
			System.out.println("main:"+i);
		}
	}
	
	private void begin(){
		MyThread mt = new MyThread();
		Thread t1 = new Thread(mt);
		t1.start();
	}
	
	class MyThread implements Runnable{

		@Override
		public void run() {
			for(int i=0;i<10;i++){
				System.out.println("mt:"+i);
			}
		}
		
	}
}
